home *** CD-ROM | disk | FTP | other *** search
/ Chip 2006 June / CHIP 2006-06.2.iso / program / freeware / Democracy-0.8.2.exe / xulrunner / python / frontend_implementation / Application.py < prev    next >
Encoding:
Python Source  |  2006-04-10  |  1.2 KB  |  44 lines

  1. import sys
  2. import frontend
  3. import time
  4. import threading
  5.  
  6. ###############################################################################
  7. #### Application object                                                    ####
  8. ###############################################################################
  9.  
  10. class Application:
  11.  
  12.     def __init__(self):
  13.     print "Application init"
  14.  
  15.     def runNonblocking(self):
  16.         import psyco
  17.         #psyco.log('\\dtv.psyco')
  18.         psyco.profile(.03)
  19.  
  20.         # Start the core.
  21.     self.onStartup()
  22.  
  23.     def getBackendDelegate(self):
  24.         return frontend.UIBackendDelegate()
  25.  
  26.     def onStartup(self):
  27.         # For overriding
  28.         pass
  29.  
  30.     def onShutdown(self):
  31.         # For overriding
  32.         pass
  33.  
  34.     # This is called on OS X when we are handling a click on an RSS feed
  35.     # button for Safari. NEEDS: add code here to register as a RSS feed
  36.     # reader on Windows too. Just call this function when we're launched
  37.     # to handle a click on a feed.
  38.     def addAndSelectFeed(self, url):
  39.         # For overriding
  40.         pass
  41.  
  42. ###############################################################################
  43. ###############################################################################
  44.